﻿@using Kugar.MVC.DaemonUI.Enums
@using Kugar.MVC.DaemonUI.Helpers
@using Kugar.MVC.DaemonUI.PageControls.PageCommons
@using WS.FlowAuth.Web.Data.EF

@{
    var info = (base_UserCode) ViewBag.Info;
}

@using (WebUI.Controls.ModalWindow()
                .Title("用户代码")
                .ContentHeight(320)
                .Width(480)
                .ID("divDetail")
                .AddButton(btn=>btn.Text("保存").Type(ButtonType.Submit).StyleType(ButtonStyleType.Primary))
                .Render()
                )
{
    using (WebUI.Form.Form().Ajax().Post().UpdateElementID("divDetail").Render())
    {
        @WebUI.Form.Text().Label("用户代码").Value(info.UserCode).Required().Name("UserCode").Render()

        @WebUI.Form.Text().Label("客户名称").Value(info.CustomerName).Required().Name("CustomerName").Render()

        @WebUI.Form.DateTimePicker().Label("过期时间").Type(DateTimePickerType.Date).Require().Current(info.ExpireDt).Name("ExpireDt").Render()

        @WebUI.Form.Label().Label("状态").Value(info.IsDeleted?"禁用":"正常").Render();
    }
}